/*
 * Copyright 2010 - 2011, The PLDesktop Development Team
 *
 *  This library is free software; you can redistribute it and/or
 *  modify it under the terms of the GNU Lesser General Public
 *  License as published by the Free Software Foundation; either
 *  version 2.1 of the License, or (at your option) any later version.
 *
 *  This library is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 *  Lesser General Public License for more details.
 *
 *  You should have received a copy of the GNU Lesser General Public
 *  License along with this library; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 *
 */

#ifndef PLJAVA_STACK_VALUE_H
#define PLJAVA_STACK_VALUE_H

namespace PLSDK {

/**
 * Base class for all values that you can push onto the stack and in the locale
 * variables buffer.
 */
class PLJavaStackValue {
public:
    /**
     * Types that can be used with the stack.
     */
    enum Types {
        /**
         * The type is a emty value.
         */
        Empty           = 0,
        /**
         * The type is from type integer.
         */
        Integer         = 1,
        /**
         * The type is from type float.
         */
        Float           = 2,
        /**
         * The type is from type double.
         */
        Double          = 3,
        /**
         * The type is from type long.
         */
        Long            = 4,
        /**
         * The type is from type Class Reference.
         */
        ClassRef        = 5,
        /**
         * The type is from type Class Array Reference.
         */
        ClassArrayRef   = 6,
        /**
         * The type is from type Array Reference.
         */
        ArrayRef        = 7
    };
    /**
     * Constructor.
     */
    PLJavaStackValue();
    /**
     * Get the type of the stack value.
     *
     * @return The type.
     */
    inline PLJavaStackValue::Types type();
protected:
    PLJavaStackValue::Types m_type;
};

PLJavaStackValue::Types PLJavaStackValue::type() {
    return m_type;
}

}

#endif
